package util;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;

public class DBConnection {
	public static Connection getConnection() {
		Connection con = null;
		try {
			Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
			con = DriverManager.getConnection("jdbc:odbc:user");
			System.out.print("DB-->OK");
		} catch (ClassNotFoundException classNotFound) {
			classNotFound.printStackTrace();
		} catch (SQLException sql) {
			sql.printStackTrace();
		}
		return con;
	}

	public static void main(String[] args) {
		new DBConnection();
	}
}
